package com.cys.dm.rest.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.cys.dm.dao.item.DmCinemaDao;
import com.cys.dm.entity.item.DmCinema;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.websocket.server.PathParam;

@RestController
public class DmCinemaService {
    @Resource
    private DmCinemaDao dmCinemaDao;

    @PostMapping(path = "/findByID")
    public DmCinema findById(@RequestParam("cinemaId") Long cinemaId){
        QueryWrapper<DmCinema> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("id",cinemaId);
        return dmCinemaDao.selectOne(queryWrapper);
    }
}
